<?php
/**
 * User: 1971229701@qq.com
 * Date: 2020/11/6/006
 * Time: 9:58
 */

namespace app\index\controller;


use think\App;
use think\Controller;
use think\Db;


class Base extends Controller
{
    public function __construct(App $app)
    {
        parent::__construct();
        // 品牌天地
        $pinpai = Db::name('config')->whereIn('id', [4, 5, 6])->select();

        // 高级私人定制系列
        $siren = Db::name('config')->whereIn('id', [17, 30])->select();
        // 售后服务
        $shouhou = Db::name('config')->whereIn('id', [16, 11, 18, 19, 20])->select();
        // 新闻资讯
        $xinwen = Db::name('config')->whereIn('id', [31, 7, 8])->order('id','desc')->select();

        $cate = Db::table('cate')->order('sort desc')->select();
        $this->assign('cate', $cate);
        $this->assign('pinpai', $pinpai);
        $this->assign('siren', $siren);
        $this->assign('shouhou', $shouhou);
        $this->assign('xinwen', $xinwen);


    }

}